<template>
  <div>
    <div class="login_box">
      <!-- 头像区域 -->
      <div class="avatar_box">
        <img src="../../assets/logo.jpeg"/>
      </div>
      <!-- 表单区域 -->
      <div class="login_form">
        <h2>网联机构白名单系统</h2>
        <el-form label-width="0px">
          <el-form-item>
            <el-input prefix-icon="iconfont icon-username" placeholder="请输入ID"></el-input>
          </el-form-item>
          <el-form-item>
            <el-input type="password" prefix-icon="iconfont icon-password" placeholder="请输入密码"></el-input>
          </el-form-item>
          <el-form-item align="right">
            <el-button type="primary" @click="$router.replace({name: 'Home'})">登录</el-button>
          </el-form-item>
        </el-form>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  name: "Login",
  data() {
    return {
      formData:{

      }
    }
  }
}
</script>

<style lang="less" scoped>
.login_container {
  background-color: #2b4b6b;
  height: 100%;
}

.login_box {
  width: 450px;
  height: 350px;
  background-color: white;
  border-radius: 1rem;
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);

  .avatar_box {
    height: 130px;
    width: 130px;
    border: 1px solid #eee;
    border-radius: 50%;
    padding: 5px;
    box-shadow: 0 0 10px #ddd;
    position: absolute;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: white;

    img {
      height: 100%;
      width: 100%;
      border-radius: 50%;
      background-color: #eee;
    }
  }
}

.login_form {
  position: absolute;
  bottom: 0;
  width: 100%;
  box-sizing: border-box;

  .el-form {
    padding: 0 110px;
  }

  h2 {
    text-align: center;
  }
}
</style>